<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:p="http://primefaces.org/ui"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:h="http://java.sun.com/jsf/html">
    <ui:composition template="/publico/template.xhtml">
        <ui:define name="content">
            <h:form id="fnovo">
                <p:messages/>
                <p:panel id="pprincipal"
                         header="Metodo de Trituracao">
                    <h:inputHidden id="ihtrituracaoid"
                                   value="#{metodoDeTrituracaoBean.metodoDeTrituracao.id}"/>
                    <h:panelGrid columns="2">  
                        <h:outputLabel 
                            for="itnomemdt" 
                            value="Nome *: "/>
                        <p:inputText 
                            id="itnomemdt" 
                            value="#{metodoDeTrituracaoBean.metodoDeTrituracao.nome}"
                            required="true"/>

                        <h:outputLabel 
                            for="itdescricaomdt" 
                            value="Descrição: "/>
                        <p:inputTextarea
                            id="itdescricaomdt" 
                            value="#{metodoDeTrituracaoBean.metodoDeTrituracao.descricao}"/>
                    </h:panelGrid>

                    <p>
                        <p:commandButton id="cbsalvar"
                                         ajax="false" 
                                         value="Salvar" 
                                         action="#{metodoDeTrituracaoBean.salvar}"/>
                        <p:button id="cbcancelar"
                                  outcome="/admin/metododetrituracao/lista-metododetrituracao.xhtml"
                                  value="Cancelar"/>
                    </p>
                </p:panel>
            </h:form>
        </ui:define>
    </ui:composition>
</html>
